package com.imdroid.notification;

public class NTeamUserLocation extends Notification {
	/**
	 * The GPS longitude
	 */
	private float targetUserId;
	/**
	 * The GPS longitude
	 */
	private String targetUserName;
	/**
	 * The GPS longitude
	 */
	private float longitude;
	/**
	 * The GPS latitude
	 */
	private float latitude;
	/**
	 * The GPS speed
	 */
	private float speed;
	/**
	 * The direction
	 */
	private float direction;
	/**
	 * The type of device
	 */
	private String deviceType;

	/**
	 * The construstor of location notification
	 * 
	 * @param targetUserId
	 *            The target user Id
	 * @param longitude
	 *            The GPS longitude
	 * @param latitude
	 *            GPS latitude
	 */
	public NTeamUserLocation(int targetUserId, float latitude, float longitude,
			float speed, String senderName, float direction, String deviceType) {
		this.targetUserId = targetUserId;
		this.targetUserName = senderName;
		this.latitude = latitude;
		this.longitude = longitude;
		this.speed = speed;
		this.direction = direction;
		this.deviceType = deviceType;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.imdroid.push.Notification#getHeader()
	 */
	protected int getHeader() {
		return Notification.NOTIFICATION_LOCATION;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see com.imdroid.push.Notification#getBody()
	 */
	protected String getBody() {
		return targetUserId + "&&" + longitude + "&&" + latitude + "&&" + speed
				+ "&&" + targetUserName + "&&" + direction + "&&" + deviceType;
	}
}